#include "ModbusAddress.h"

bool CModbusAddress::IsStackData(int iModbusAddress)
{
    return (STACK_DATA == iModbusAddress);
}

bool CModbusAddress::IsBankData(int iModbusAddress)
{
    return (iModbusAddress >= BANK_DATA_MIN && iModbusAddress <= BANK_DATA_MAX);
}

bool CModbusAddress::IsHoldReg(int iModbusAddress)
{
    return (HOLD_REGISTER == iModbusAddress);
}

bool CModbusAddress::IsInputReg(int iModbusAddress)
{
    return (INPUT_REGISTER == iModbusAddress);
}

bool CModbusAddress::IsEnvData(int iModbusAddress)
{
    return (iModbusAddress >= ENV_DATA_MIN && iModbusAddress <= ENV_DATA_MAX);
}
